package ecom.ejb;

import java.util.List;

/**
 *
 * @author François
 */
public interface EuroConverterRemote {
    /**
     * @author François Haurit
     * @version 1.0
     */
    public enum Devise {
	/**
	 * Valeur nominale
	 */
	EUR("Euro", 1.0, "€"),
	/**
	 * Franc.
	 */
	FRF("FRF Franc français", 6.55957, "F"),
	/**
	 * deutschemark .
	 */
	DEM("DEM deutschemark ", 1.95583, "DM"),
	/**
	 * Dollar
	 */
	USD("USD Dollar Américain", 1.4, "$");

	private String nom;

	private double taux;

	private String symbole;

	private Devise(String nom, double taux, String symbole) {
	    this.nom = nom;
	    this.taux = taux;
	    this.symbole = symbole;
	}

	public String getNom() {
	    return this.nom;
	}

	public double getTaux() {
	    return this.taux;
	}

	public String getSymbole() {
	    return this.symbole;
	}
    }

    double convertToEuro(double amount, Devise devise);

    double convertFromEuro(double amount, Devise devise);

    double convertCurrency(double amount, Devise deviseSource,
	    Devise deviseCible);

    List<String> getSymbolesDevises();

    Devise getDeviseFromSymbole(String symbole);
}
